﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace TimScripts.BF4Rcon
{
    internal class RoundOverState
    {
        private int? _TeamId;
        internal int TeamId
        {
            get { return _TeamId.Value; }

            set { _TeamId = value; }
        }

        internal IPlayerCollection Players { get; set; }

        internal IList<int> TeamScores { get; set; }

        private int? _TargetScore;
        internal int TargetScore
        {
            get { return _TargetScore.Value; }

            set { _TargetScore = value; }
        }

        internal bool HasAllData
        {
            get
            {
                return Players != null &&
                    _TargetScore.HasValue &&
                    _TeamId.HasValue &&
                    TeamScores != null;
            }
        }

        internal void Reset()
        {
            _TeamId = null;
            Players = null;
            TeamScores = null;
            _TargetScore = null;
        }
    }
}
